package com.qianfeng.smartdevice.event;

// 这个是通知设备发生状态变化 比如上线或者是下线
public class DeviceStatusChangeEvent {
    private String devicesuuid;//哪个设备

    private String status;//变化的状态

    //上线
    public static  DeviceStatusChangeEvent onLine(String devicesuuid){
        DeviceStatusChangeEvent event = new DeviceStatusChangeEvent();
        event.devicesuuid = devicesuuid;
        event.status = "1";
        return event;
    }

    //离线
    public static  DeviceStatusChangeEvent offLine(String devicesuuid){
        DeviceStatusChangeEvent event = new DeviceStatusChangeEvent();
        event.devicesuuid = devicesuuid;
        event.status = "0";
        return event;
    }

    public String getDevicesuuid() {
        return devicesuuid;
    }

    public String getStatus() {
        return status;
    }
}
